﻿using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace mvchotleweb.Controllers
{
    public class HomeController : Controller
    {
        public ActionResult Index()
        {
            return View();
        }
        public ActionResult Sever()
        {


            return View();
        }

        public ActionResult Booking()
        {


            return View();
        }

        public ActionResult Rooms()
        {


            return View();
        }

        public ActionResult Locations()
        {


            return View();
        }

        public ActionResult News()
        {
            return View();
        }

        public ActionResult GetNewsContent()
        {
            int  id = Convert.ToInt32(Request.Form["id"]);
            hotel.BLL.view_newlist vebll = new hotel.BLL.view_newlist();
            hotel.Model.view_newlist mod = new hotel.Model.view_newlist();
            mod = vebll.GetModel(id);
            return Content(Newtonsoft.Json.JsonConvert.SerializeObject(mod), "application/Json");
        }

    }
}
